'游戏相机，跟随玩家'

extends Camera2D

var player_node = null

func _ready() -> void:
	make_current()#强制该相机成为主相机
	pass


func _process(delta: float) -> void:
	player_node = get_tree().get_first_node_in_group("player")
	if player_node == null:
		return
	self.global_position = self.global_position.lerp(player_node.global_position,1.0 - exp(-delta * 20))
	pass
